package com.coder.code.ui

import android.os.Bundle
import androidx.appcompat.app.AppCompatActivity
import com.coder.code.R
import com.coder.code.databinding.ActivityMotionLayout3Binding

/**
 * @description TODO
 * @author yuhus
 * @date 2021/12/7 20:11
 */
class MotionLayoutActivity3 : AppCompatActivity() {
    private val binding by lazy { ActivityMotionLayout3Binding.inflate(layoutInflater) }

    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(binding.root)

        binding.icon233.setOnClickListener {
            binding.motionLayout.transitionToState(R.id.motion_expand)
            binding.motionBg.transitionToState(R.id.motion_expand)
        }
        binding.quiteGame.setOnClickListener {
            binding.motionLayout.transitionToState(R.id.motion_collapse)
            binding.motionBg.transitionToState(R.id.motion_collapse)
        }
    }
}